home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
System Booster
/
System Booster.iso
/
Archives
/
Timing
/
DateBKIV.lha
/
DateBookIV
/
Rexx
/
Add_Alarm.dbk
next >
Wrap
Text File
|
1994-05-08
|
1KB
|
59 lines
/* File : Add_Alarm.dbk
*
* $Project:
*
* $Module Id:
* $Author: Robert Hardy
* $Date Started: Thu Apr 21 1994
* $Version: 1
* $Revision 0
*
* Add an event to CyberCrons task list.
* Rexx field should be: `Add_Alarm %T <lead_time> <message>'
*
* Where:
* %T - DateBook will insert the event's
* time field.
* lead_time - number of minutes prior to event
* time.
* message - The rest of the line contains the
* message to display.
*
* $History:
* {ver} {initial} {date} {description of change} {SAR|SCR reference #}
*
* 1.0 RWH Thu Apr 21 1994 Initial rev
*
*/
parse arg event_time lead_time message
options results
Ding = '07'X
/* Set up the window to display our message */
window_string = '>con:10/10/400/50/Reminder/close/wait'
event_time = strip(event_time)
/* extract time */
hours = left(event_time, 2)
mins = right(event_time, 2)
mins = mins - lead_time /* Subtract lead time */
do while mins < 0 /* Adjust as needed */
mins = mins + 60
hours = hours - 1
end
message = Ding || Ding || message || Ding || Ding
command_string = echo "'message'" 'window_string
address 'CYBERCRON' /* talk to CyberCron's rexx port */
ADD_EVENT mins' 'hours' * * * 'command_string
exit 0
/* End Add_Alarm.dbk */